import request from '@/utils/request'

export function getSingleProxyList(data: any) {
  return request({
    url: '/supplier/proxy_order/list',
    method: 'get',
    params: data,
  })
}

// 发货
export function sendSingleProxy(data: any) {
  return request({
    url: '/supplier/proxy_order/edit_shipment',
    method: 'post',
    data,
  })
}

// 获取单据信息
export function getSingleProxyInfo(data: any) {
  return request({
    url: '/supplier/proxy_order/info',
    method: 'get',
    params: data,
  })
}

// 基本信息
export function getSingleProxyBaseInfo() {
  return request({
    url: '/supplier/proxy_order/base_info',
    method: 'get',
  })
}

// 新增代客下单订单
export function addSingleProxySubmit(data: any) {
  return request({
    url: '/supplier/proxy_order/placeOrder',
    method: 'post',
    data,
  })
}
// 编辑代客单 单价
export function editSingleProxyPrice(data: any) {
  return request({
    url: '/supplier/proxy_order/price',
    method: 'post',
    data,
  })
}

// 代客单结款  //仅仅是结款一个状态显示 不涉及业务员
export function paymentSingleProxy(data: any) {
  return request({
    url: '/supplier/proxy_order/settle_payment_status',
    method: 'post',
    data,
  })
}

// 新的代客下单逻辑

// 获取所有的店铺品牌
export const getProxyStoreBrandList = (data) => {
  return request({
    url: '/supplier/shop/shopBrandList',
    method: 'get',
    params: data,
  })
}
// 获取店铺里面的商品列表
export const getProxyStoreGoodsList = (data) => {
  return request({
    url: '/supplier/goods/getGoodsDiscount',
    method: 'get',
    params: data,
  })
}
// 获取店铺里面的规格列表
export const getProxyStoreSpecList = (data) => {
  return request({
    url: '/supplier/goods/getGoodsSku',
    method: 'get',
    params: data,
  })
}